The invention relates to a method and a device for generating a digital signal from an analog signal generated using a frequency converter on the basis of pulse width modulation with a variable period duration, values of the digital signal corresponding to an average value of the analog signal over an associated period duration of the pulse width modulation.
Conventional frequency converters typically output a so-called phase voltage which is generated on the basis of pulse width modulation. An effective voltage generated using the frequency converter at a winding of a multiphase electric motor is the difference between two such phase voltages. For the rest, reference is also made to the relevant specialist literature.
During the controlled driving of electric motors, it may be necessary to determine the DC voltage component of the pulse-width-modulated voltage or of the effective motor voltage.
GB 2 440 559 A describes a method in which a pulse-width-modulated voltage generated by a frequency converter is digitized using a sigma-delta modulator. In order to determine a respective digital measured voltage value, an integral is continuously formed over precisely one associated period duration of the pulse width modulation. This formation of an integral corresponds to a first-order Hogenauer filter.
Frequency converters are often operated in a group and are synchronized in this case using a superordinate controller. During synchronization, the need may arise to change the period duration on which the pulse width modulation is based.
In the method described in GB 2 440 559 A, a change in the period duration could be regenerated by accordingly taking into account more or fewer modulator clocks in the integration.
If higher-order digital filters are required on account of the demands imposed on the signal quality, a bit stream output by a sigma-delta modulator may be filtered, for example, using a higher-order, for example a second-order or third-order, Hogenauer filter.
The transfer function of such Hogenauer filters is determined by a clock of the bit stream output by the sigma-delta modulator (modulator clock), a filter order and the so-called oversampling ratio. The oversampling ratio describes the ratio between the input sampling rate and the output sampling rate generated during sampling rate conversion, that is to say the ratio between the modulator clock and the clock of the filtered values or samples output by the filter. The sampling rate consequently results from the modulator clock divided by the oversampling ratio. For the rest, reference is also made to the relevant specialist literature in this respect.
In order to be able to measure the voltage in a pulse-width-modulating system using a Hogenauer filter, the resulting sampling rate of the Hogenauer filter must be an integer multiple of the fundamental frequency of the pulse width modulation as exactly as possible in order to be able to effectively suppress the switching frequency. An integral or average value can then be formed over these samples within a respective period of the pulse width modulation in order to apply the notch frequency to the switching frequency.
In order to adapt the above-mentioned method to a variable period duration of the pulse width modulation, the modulator clock can be dynamically adapted to the period duration, for example. However, jitter of the modulator clock or omission of clocks results in a considerable reduction in the maximum possible number of effective bits (ENOB). Alternatively or additionally, the oversampling ratio can be dynamically adapted to the period duration of the pulse width modulation, but this results in miscalculations during adaptation in the Hogenauer filter and also influences the frequency behavior and the gain of the Hogenauer filter.
The invention is based on the object of providing a method and a device for generating a digital signal from an analog signal generated using a frequency converter on the basis of pulse width modulation with a variable period duration, which method and device can be easily adapted to a variable period duration and can be used to implement filters with an order of greater than one.
The invention achieves this object by means of a method and a device according to embodiments of the invention.
The method is used to produce a digital signal from an analog signal which is generated using a frequency converter on the basis of pulse width modulation with a variable period duration. Values of the digital signal correspond to an average value of the analog signal over an associated period duration of the pulse width modulation.
The digital signal or its values is/are continuously generated for each period of the pulse-width-modulated analog signal. The values of the digital signal have a delimited and graduated set of values. The digital signal may also be defined, in terms of its temporal sequence, only at particular periodic times, for example at the end of a respective period of the pulse-width-modulated analog signal, or may have a change in its values. The digital signal is formed from the analog signal, which describes the temporally continuous profile of a physical variable, for example current or voltage, by means of sampling, which is carried out at defined times, and quantization. Corresponding coding can be used to convert the digital signal or its values into a binary representation, for example with a digital word length of 8, 16, 24 or 32 bits.
In the method, a bit stream (binary range of values of zero and one) is generated on the basis of the analog signal using a conventional sigma-delta modulator, the bit stream being generated with a constant modulator clock, for example in a modulator clock range of between 5 MHz and 50 MHz.
A plurality of temporally successive digital samples are generated from the bit stream generated in this manner during a respective period duration or a respective period of the pulse width modulation. The digital samples can be coded in a binary manner with a word length of 2, 4, 8, 16 or 32 bits, for example.
Intervals of time between respective successive digital samples are integer multiples of the modulator clock.
The operation of generating the temporally successive digital samples comprises the following steps:
The bit stream is filtered using a number of (at least two) independent digital, in particular sampling-rate-reducing, filters for generating the digital samples, the digital filters being started with a time delay at the desired interval of time between the successive digital samples. After a respective filter has been started, the bit string can be applied to the filter in the modulator clock and the filter can process the bit values in the bit string according to its filter function, can reduce the bit rate, can output its associated digital sample after a processing period, etc.
The period duration can be represented in multiples of the modulator clock. If the period duration is k modulator clocks and a number of samples, which are generated during a respective period duration or a respective period of the pulse width modulation and are distributed over the respective period duration or respective period, is r, the intervals of time between successive digital samples are each set to k/r modulator clocks, provided that k can be divided by r without a remainder. For this situation, the digital samples are distributed in a completely equidistant manner over the period duration or period.
If k cannot be divided by r without a remainder, the intervals of time between successive samples are set in such a manner that a distribution of the samples which is as temporally equidistant as possible over the period duration or period results, in which case a sum of the intervals of time between the successive samples is equal to the period duration.
If the period duration in modulator clock units is k=31 and the number of samples is r=3 as a numerical example, the intervals of time in modulator clock units may be (11, 10, 10), (10, 11, 10) or (10, 10, 11).
If the period duration in modulator clock units is k=32 and r=3 as another numerical example, the intervals of time may be (11, 11, 10), (10, 11, 11) or (11, 10, 11).
Finally, if the period duration in modulator clock units is k=33 and r=3 as another numerical example, the intervals of time (11, 11, 11) are selected as an equidistant distribution.
The digital filters may be operated or may operate at least temporarily in a temporally overlapping manner during the period duration or period.
A respective digital filter outputs an associated digital sample, the digital samples likewise being output by the different digital filters with a temporal distance from one another.
A value of the digital signal which belongs to the respective period duration or period and represents the average value of the analog signal over the period duration or period is calculated by forming an average value of the digital samples generated during the period duration or period.
The intervals of time between the digital samples may be set or calculated on the basis of the variable period duration PD. The number of digital samples per period duration or period may be stipulated as constant irrespective of the period duration. It is only necessary to ensure that a distribution of the digital samples which is as equidistant as possible within the period duration or period results. In other words, the intervals of time between the digital samples are set or calculated on the basis of the variable period duration PD in such a manner that a distribution of the digital samples which is as temporally equidistant as possible over the period or period duration results.
A respective digital filter may have or implement a sinc3 filter function.
A respective digital filter may be designed to output an associated digital sample every n modulator clocks.
The intervals of time between the temporally successive digital samples in modulator clock units may each be smaller than n in order to avoid weighting gaps.
The number of digital filters may be selected to be equal to the number of digital samples per period duration of the pulse width modulation, that is to say each digital filter outputs precisely one associated digital sample.
Alternatively, the number of digital filters may be selected to be smaller than the number of digital samples per period duration of the pulse width modulation, that is to say a digital filter outputs more than only an individual associated digital sample in succession over the course of the period duration or period. For this situation, the digital filter is restarted immediately or after a waiting time after it has output a digital sample.
64≦n≦128 may apply.
The digital filters may each have identical weighting functions (pulse response), the digital filters being started with a time delay with respect to one another in such a manner that weighting functions of digital filters which produce temporally adjacent digital samples at least partially overlap.
The period duration of the pulse width modulation may be in a range between 62.5 μs and 1 ms.
The device for generating a digital signal from an analog signal generated using a frequency converter on the basis of pulse width modulation with a variable period duration is designed to carry out the method mentioned above. The device has: a sigma-delta modulator for generating the bit stream, a number of (at least two) digital filters for filtering the bit stream and generating the digital samples, and an averager for forming the average value of the digital samples generated during the period duration.